package com.hzf.order.dao.model;

import com.hzf.material.dao.model.MaterialGoods;
import com.hzf.material.dao.model.MaterialGoodsModel;

import java.io.Serializable;
import java.math.BigDecimal;

public class OrderUserInfo implements Serializable {
    private Integer orderUserInfoId;

    private Integer orderUserId;

    private Integer shopId;

    private Integer goodsId;

    private Integer modelId;

    private Integer count;

    private Double price;

    private Long createTime;

    private Long payTime;

    private Integer payState;//0:未支付，//1：未发货，//2：已发货，//3已收货，//4已评价打款

    private Integer userId;

    private Double distributionFee;

    private Integer receivingState;

    private Long receivingTime;

    private MaterialGoods materialGoods;

    private MaterialGoodsModel materialGoodsModel;

    private static final long serialVersionUID = 1L;

    public Integer getOrderUserInfoId() {
        return orderUserInfoId;
    }

    public void setOrderUserInfoId(Integer orderUserInfoId) {
        this.orderUserInfoId = orderUserInfoId;
    }

    public Integer getOrderUserId() {
        return orderUserId;
    }

    public void setOrderUserId(Integer orderUserId) {
        this.orderUserId = orderUserId;
    }

    public Integer getShopId() {
        return shopId;
    }

    public void setShopId(Integer shopId) {
        this.shopId = shopId;
    }

    public Integer getGoodsId() {
        return goodsId;
    }

    public void setGoodsId(Integer goodsId) {
        this.goodsId = goodsId;
    }

    public Integer getModelId() {
        return modelId;
    }

    public void setModelId(Integer modelId) {
        this.modelId = modelId;
    }

    public Integer getCount() {
        return count;
    }

    public void setCount(Integer count) {
        this.count = count;
    }

    public Double getPrice() {
        return price;
    }

    public void setPrice(Double price) {
        this.price = price;
    }

    public Long getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Long createTime) {
        this.createTime = createTime;
    }

    public Long getPayTime() {
        return payTime;
    }

    public void setPayTime(Long payTime) {
        this.payTime = payTime;
    }

    public Integer getPayState() {
        return payState;
    }

    public void setPayState(Integer payState) {
        this.payState = payState;
    }

    public Double getDistributionFee() {
        return distributionFee;
    }

    public void setDistributionFee(Double distributionFee) {
        this.distributionFee = distributionFee;
    }

    public Integer getReceivingState() {
        return receivingState;
    }

    public void setReceivingState(Integer receivingState) {
        this.receivingState = receivingState;
    }

    public Long getReceivingTime() {
        return receivingTime;
    }

    public void setReceivingTime(Long receivingTime) {
        this.receivingTime = receivingTime;
    }

    public MaterialGoods getMaterialGoods() {
        return materialGoods;
    }

    public void setMaterialGoods(MaterialGoods materialGoods) {
        this.materialGoods = materialGoods;
    }

    public MaterialGoodsModel getMaterialGoodsModel() {
        return materialGoodsModel;
    }

    public void setMaterialGoodsModel(MaterialGoodsModel materialGoodsModel) {
        this.materialGoodsModel = materialGoodsModel;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", orderUserInfoId=").append(orderUserInfoId);
        sb.append(", orderUserId=").append(orderUserId);
        sb.append(", shopId=").append(shopId);
        sb.append(", goodsId=").append(goodsId);
        sb.append(", modelId=").append(modelId);
        sb.append(", count=").append(count);
        sb.append(", price=").append(price);
        sb.append(", createTime=").append(createTime);
        sb.append(", payTime=").append(payTime);
        sb.append(", payState=").append(payState);
        sb.append(", distributionFee=").append(distributionFee);
        sb.append(", receivingState=").append(receivingState);
        sb.append(", receivingTime=").append(receivingTime);
        sb.append("]");
        return sb.toString();
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        OrderUserInfo other = (OrderUserInfo) that;
        return (this.getOrderUserInfoId() == null ? other.getOrderUserInfoId() == null : this.getOrderUserInfoId().equals(other.getOrderUserInfoId()))
            && (this.getOrderUserId() == null ? other.getOrderUserId() == null : this.getOrderUserId().equals(other.getOrderUserId()))
            && (this.getShopId() == null ? other.getShopId() == null : this.getShopId().equals(other.getShopId()))
            && (this.getGoodsId() == null ? other.getGoodsId() == null : this.getGoodsId().equals(other.getGoodsId()))
            && (this.getModelId() == null ? other.getModelId() == null : this.getModelId().equals(other.getModelId()))
            && (this.getCount() == null ? other.getCount() == null : this.getCount().equals(other.getCount()))
            && (this.getPrice() == null ? other.getPrice() == null : this.getPrice().equals(other.getPrice()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getPayTime() == null ? other.getPayTime() == null : this.getPayTime().equals(other.getPayTime()))
            && (this.getPayState() == null ? other.getPayState() == null : this.getPayState().equals(other.getPayState()))
            && (this.getDistributionFee() == null ? other.getDistributionFee() == null : this.getDistributionFee().equals(other.getDistributionFee()))
            && (this.getReceivingState() == null ? other.getReceivingState() == null : this.getReceivingState().equals(other.getReceivingState()))
            && (this.getReceivingTime() == null ? other.getReceivingTime() == null : this.getReceivingTime().equals(other.getReceivingTime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getOrderUserInfoId() == null) ? 0 : getOrderUserInfoId().hashCode());
        result = prime * result + ((getOrderUserId() == null) ? 0 : getOrderUserId().hashCode());
        result = prime * result + ((getShopId() == null) ? 0 : getShopId().hashCode());
        result = prime * result + ((getGoodsId() == null) ? 0 : getGoodsId().hashCode());
        result = prime * result + ((getModelId() == null) ? 0 : getModelId().hashCode());
        result = prime * result + ((getCount() == null) ? 0 : getCount().hashCode());
        result = prime * result + ((getPrice() == null) ? 0 : getPrice().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getPayTime() == null) ? 0 : getPayTime().hashCode());
        result = prime * result + ((getPayState() == null) ? 0 : getPayState().hashCode());
        result = prime * result + ((getDistributionFee() == null) ? 0 : getDistributionFee().hashCode());
        result = prime * result + ((getReceivingState() == null) ? 0 : getReceivingState().hashCode());
        result = prime * result + ((getReceivingTime() == null) ? 0 : getReceivingTime().hashCode());
        return result;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }
}